<ion-view title="通讯录" scroll="false">
    <ion-nav-buttons side="left">
        <button class="button back-button buttons icon ion-ios-arrow-left button-clear header-item" nav-direction="back" ui-sref="menu">返回</button>
    </ion-nav-buttons>
    <ion-tabs class="tabs-top tabs-stable tabs-color-positive">
        <ion-tab title="收货人" class="tabs-item">
            <ion-view>
                <ion-content on-drag-left="dragLeftShr()">
                    <ion-refresher
                            pulling-text="下拉刷新..."
                            on-refresh="doRefreshShr()">
                    </ion-refresher>
                    <div ng-if="showloading" style="margin-top:60px; text-align: center">
                        <ion-spinner icon="ios" style="height: 60px; width: 60px;"></ion-spinner>
                    </div>
                    <div ng-if="showloading == false" class="content">
                        <div class="bar bar-header item-input-inset">
                            <label class="item-input-wrapper">
                                <i class="icon ion-ios-search placeholder-icon"></i>
                                <input type="search" placeholder="搜索" ng-model="search.content" ng-change="searchLinkman(search.content,1)">
                            </label>
                        </div>
                        <h5 ng-if="mailListShr==''" style="color: #69717d;text-align: center;margin-top: 50px;">未找到数据</h5>
                        <ul class="list">
                            <li class="item" collection-repeat="linkmanShr in mailListShr" on-hold="deleteShr(linkmanShr)" ng-click="callPhone(linkmanShr.lxdh)">
                                <i ng-if="linkmanShr.khmc!=''" style="margin-left: 10px;font-size: 16px;">{{linkmanShr.khmc}}</i>
                                <i ng-if="linkmanShr.lxdh!=''" style="font-size: 13px;margin-right: 10px;float: right;">{{linkmanShr.lxdh}}</i>
                            </li>
                        </ul>
                    </div>
                    <ion-infinite-scroll   on-infinite="loadMoreShr()"  distance="1%" ng-if="hasNextPageShr()"></ion-infinite-scroll>
                </ion-content>
            </ion-view>
        </ion-tab>
        <ion-tab title="发货人" class="tabs-item">
            <ion-view>
                <ion-content on-drag-left="dragLeftFhr()" on-drag-right="dragRightFhr()">
                    <ion-refresher
                            pulling-text="下拉刷新..."
                            on-refresh="doRefreshFhr()">
                    </ion-refresher>
                    <div ng-if="showloading" style="margin-top:60px; text-align: center">
                        <ion-spinner icon="ios" style="height: 60px; width: 60px;"></ion-spinner>
                    </div>
                    <div ng-if="showloading == false" class="content">
                        <div class="bar bar-header item-input-inset">
                            <label class="item-input-wrapper">
                                <i class="icon ion-ios-search placeholder-icon"></i>
                                <input type="search" placeholder="搜索" ng-model="search.content" ng-change="searchLinkman(search.content,2)">
                            </label>
                        </div>
                        <h5 ng-if="mailListFhr==''" style="color: #69717d;text-align: center;margin-top: 50px;">未找到数据</h5>
                        <ul class="list">
                            <li class="item" collection-repeat="linkmanFhr in mailListFhr" on-hold="deleteFhr(linkmanFhr)" ng-click="callPhone(linkmanFhr.lxdh)">
                                <i ng-if="linkmanFhr.khmc!=''" style="margin-left: 10px;font-size: 16px;">{{linkmanFhr.khmc}}</i>
                                <i ng-if="linkmanFhr.lxdh!=''" style="font-size: 13px;margin-right: 10px;float: right;">{{linkmanFhr.lxdh}}</i>
                            </li>
                        </ul>
                    </div>
                    <ion-infinite-scroll   on-infinite="loadMoreFhr()"  distance="1%" ng-if="hasNextPageFhr()"></ion-infinite-scroll>
                </ion-content>
            </ion-view>
        </ion-tab>
        <ion-tab title="司机" class="tabs-item">
            <ion-view>
                <ion-content on-drag-left="dragLeftSj()" on-drag-right="dragRightSj()">
                    <ion-refresher
                            pulling-text="下拉刷新..."
                            on-refresh="doRefreshSj()">
                    </ion-refresher>
                    <div ng-if="showloading" style="margin-top:60px; text-align: center">
                        <ion-spinner icon="ios" style="height: 60px; width: 60px;"></ion-spinner>
                    </div>
                    <div ng-if="showloading == false" class="content">
                        <div class="bar bar-header item-input-inset">
                            <label class="item-input-wrapper">
                                <i class="icon ion-ios-search placeholder-icon"></i>
                                <input type="search" placeholder="搜索" ng-model="search.content" ng-change="searchLinkman(search.content,3)">
                            </label>
                        </div>
                        <h5 ng-if="mailListSj==''" style="color: #69717d;text-align: center;margin-top: 50px;">未找到数据</h5>
                        <ul class="list">
                            <li class="item" collection-repeat="linkmanSj in mailListSj" ng-click="callPhone(linkmanSj.lxdh)">
                                <i ng-if="linkmanSj.yhmc!=''" style="margin-left: 10px;font-size: 16px;">{{linkmanSj.yhmc}}</i>
                                <i ng-if="linkmanSj.lxdh!=''" style="font-size: 13px;margin-right: 10px;float: right;">{{linkmanSj.lxdh}}</i>
                            </li>
                        </ul>
                    </div>
                    <ion-infinite-scroll   on-infinite="loadMoreSj()"  distance="1%" ng-if="hasNextPageSj()"></ion-infinite-scroll>
                </ion-content>
            </ion-view>
        </ion-tab>
        <ion-tab title="合作公司" class="tabs-item" ng-controller="PartnerCtrl">
            <ion-view>
                <ion-content on-drag-right="dragRightPartner()">
                    <ion-refresher
                            pulling-text="下拉刷新..."
                            on-refresh="doRefresh()">
                    </ion-refresher>
                    <div ng-if="showloading" style="margin-top:60px; text-align: center">
                        <ion-spinner icon="ios" style="height: 60px; width: 60px;"></ion-spinner>
                    </div>
                    <div ng-if="showloading == false" class="content">
                        <div class="bar bar-header item-input-inset">
                            <label class="item-input-wrapper">
                                <i class="icon ion-ios-search placeholder-icon"></i>
                                <input type="search" placeholder="搜索" ng-model="search.content" ng-change="searchPar(search.content)">
                            </label>
                        </div>
                        <h5 ng-if="partnerData==''" style="color: #69717d;text-align: center;margin-top: 50px;">未找到数据</h5>
                        <ul class="list">
                            <li class="item" collection-repeat="par in partnerData" ng-click="callPhone(par.gsdh)">
                                <i ng-if="par.gsmc!=''" style="margin-left: 10px;font-size: 16px;">{{par.gsmc}}</i>
                                <i ng-if="par.gsdh!=''" style="font-size: 13px;margin-right: 10px;float: right;">{{par.gsdh}}</i>
                            </li>
                        </ul>
                    </div>
                    <ion-infinite-scroll   on-infinite="loadMore()"  distance="1%" ng-if="hasNextPage()"></ion-infinite-scroll>
                </ion-content>
            </ion-view>
        </ion-tab>
   </ion-tabs>
</ion-view>
